 /*
 * @description: 创建同校班级
 * @Author: along
 * @Date: 2021-07-19
 * @Last Modified by: along
 * @Last Modified time: 2021-07-19
 */
<template>
    <div
        class="container createClass"
        ref="wrapper"
    >
        <div class="__nav">
            <p class="__nav_title">
                创建同校班级
            </p>
        </div>
        <!-- header -->
        <div class="header-nav">
            <div class="header_left">
                <div class="__info">
                    <p class="__info_title">创建用户信息</p>
                    <el-input
                        v-model="formData.keyword"
                        placeholder="请输入用户昵称/ID/手机号"
                        size="small"
                        clearable
                        suffix-icon="el-icon-search"
                        @change="getTableData(1)"
                        @keyup.native.enter="getTableData(1)"
                        :style="{width: '300px'}"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">学校名称</p>
                    <el-input
                        v-model="formData.school_name"
                        placeholder="请输入学校名称"
                        size="small"
                        clearable
                        suffix-icon="el-icon-search"
                        @change="getTableData(1)"
                        @keyup.native.enter="getTableData(1)"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">学院名称</p>
                    <el-input
                        v-model="formData.college_name"
                        placeholder="请输入学院名称"
                        size="small"
                        clearable
                        suffix-icon="el-icon-search"
                        @change="getTableData(1)"
                        @keyup.native.enter="getTableData(1)"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">班级名称</p>
                    <el-input
                        v-model="formData.class_name"
                        placeholder="请输入班级名称"
                        size="small"
                        clearable
                        suffix-icon="el-icon-search"
                        @change="getTableData(1)"
                        @keyup.native.enter="getTableData(1)"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">专业名称</p>
                    <el-input
                        v-model="formData.major_name"
                        placeholder="请输入专业名称"
                        size="small"
                        clearable
                        suffix-icon="el-icon-search"
                        @change="getTableData(1)"
                        @keyup.native.enter="getTableData(1)"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">审核人</p>
                    <el-input
                        v-model="formData.audit_people"
                        placeholder="请输入审核人"
                        size="small"
                        clearable
                        suffix-icon="el-icon-search"
                        @change="getTableData(1)"
                        @keyup.native.enter="getTableData(1)"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">审核状态</p>
                    <el-select
                        v-model="formData.status"
                        clearable
                        filterable
                        placeholder="请选择"
                        size="small"
                        @change="getTableData(1)"
                    >
                        <el-option
                            v-for="item in auditList"
                            :key="item.value"
                            :label="item.label"
                            :value="item.value"
                        />
                    </el-select>
                </div>
                <div class="__info">
                    <p class="__info_title">提交时间</p>
                    <el-date-picker
                        v-model="date"
                        type="datetimerange"
                        :picker-options="pickerOptions()"
                        range-separator="至"
                        start-placeholder="开始日期"
                        end-placeholder="结束日期"
                        :default-time="['00:00:00', '23:59:59']"
                        align="right"
                        size="small"
                        @change="getTableData(1)"
                    />
                </div>
                <div class="__info">
                    <p class="__info_title">奖励时间</p>
                    <el-date-picker
                        v-model="award_date"
                        type="datetimerange"
                        :picker-options="pickerOptions()"
                        range-separator="至"
                        start-placeholder="开始日期"
                        end-placeholder="结束日期"
                        :default-time="['00:00:00', '23:59:59']"
                        align="right"
                        size="small"
                        @change="getTableData(1)"
                    />
                </div>
                <div
                    class="__info"
                >
                    <el-button
                        type="primary"
                        size="medium"
                        :style="{marginRight: '15px'}"
                        @click="handleNextPage('createClassStatistics')"
                    >
                        数据统计
                    </el-button>

                    <el-button
                        type="primary"
                        size="medium"
                        :style="{marginRight: '15px'}"
                        @click="handleNextPage('createClassConfig')"
                    >
                        功能设置
                    </el-button>

                    <el-button
                        type="primary"
                        size="medium"
                        :style="{marginRight: '15px'}"
                        @click="handleNextPage('createClassRank')"
                    >
                        用户奖励排行
                    </el-button>
                </div>
            </div>
        </div>
        <!-- /header -->

        <!-- table -->
        <div class="__wrap">
            <el-table
                :data="tableData"
                height="100%"
                style="width: 100%;"
                border
                ref="createClass"
            >
                <el-table-column
                    type="index"
                    width="80"
                    label="序号"
                    align="center"
                />
                <el-table-column
                    label="创建用户信息"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="180"
                >
                    <template slot-scope="scope">
                        <div class="__items">
                            <p>{{ scope.row.true_name }}</p>
                            <p>{{ scope.row.phone }}</p>
                            <p>ID: {{ scope.row.student_no }}</p>
                        </div>
                    </template>
                </el-table-column>
                <el-table-column
                    prop="agent_level"
                    label="校园精英等级"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="120"
                >
                    <template slot-scope="scope">
                        E{{ scope.row.agent_level }}
                    </template>
                </el-table-column>
                <el-table-column
                    prop="school_name"
                    label="学校信息"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="140"
                />
                <el-table-column
                    prop="college_name"
                    label="学院信息"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="120"
                />
                <el-table-column
                    prop="major_name"
                    label="专业信息"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="150"
                />
                <el-table-column
                    prop="class_name"
                    label="班级信息"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="120"
                />
                <el-table-column
                    prop="enter_school_year"
                    label="入学年份"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                />
                <el-table-column
                    prop="class_group_number"
                    label="班级群号"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="150"
                />
                <!-- <el-table-column
                    prop=""
                    label="班级群录屏视频"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="140"
                >
                    <template slot-scope="">
                        <div
                            :style="{
                                background: `url(${ 'http://pic.wxhand.com/dev/wei_image/8e5d889312a69a840469bf8cf8957f1d.jpg' }) center center no-repeat`,
                                backgroundSize: 'cover'
                            }"
                            class="__video"
                            @click="previewVideo({
                                video_url: 'http://dl.zsdx.cn/course/20210622/1618/b75c9eb1e26ebfe67235f6af2a8a6597.mp4?_upt=69a154c01626677622'
                            })"
                        >
                            <img
                                src="@/assets/image/video-play.png"
                                class="__video_play"
                            >
                        </div>
                    </template>
                </el-table-column> -->
                <el-table-column
                    prop="submit_time"
                    label="提交时间"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="150"
                >
                    <template slot-scope="scope">
                        {{ scope.row.submit_time * 1000 | dateFormatter('yyyy/MM/dd HH:mm') }}
                    </template>
                </el-table-column>
                <el-table-column
                    prop="award_admin_true_name"
                    label="审核人"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                />
                <el-table-column
                    prop="award_status"
                    label="审核状态"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                >
                    <template slot-scope="scope">
                        <div
                            :style="{
                                display: 'flex'
                        }">
                            <p
                                :style="{
                                    width: '6px',
                                    height: '6px',
                                    borderRadius: '50%',
                                    color: scope.row.award_status === -1 || scope.row.award_status === 0 ? 'rgba(249, 91, 86, 1)' : scope.row.award_status === 1 ? 'rgba(255, 142, 57, 1)' : 'rgba(76, 217, 100, 1)'
                                }"
                            />
                            {{ scope.row.award_status | filterStatus }}
                        </div>
                    </template>
                </el-table-column>
                <el-table-column
                    prop="award_time"
                    label="奖励到账时间"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="150"
                >
                    <template slot-scope="scope">
                        {{ scope.row.award_time * 1000 | dateFormatter('yyyy/MM/dd HH:mm') }}
                    </template>
                </el-table-column>
                <el-table-column
                    prop="award_money"
                    label="奖励金额(元)"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="120"
                />
                <el-table-column
                    prop="remark"
                    label="备注"
                    show-overflow-tooltip
                    :formatter="emptyFormatter"
                    align="left"
                    :width="150"
                />
                <el-table-column
                    label="操作"
                    align="left"
                    fixed="right"
                    :width="130"
                >
                    <template slot-scope="scope">
                        <el-button
                            type="text"
                            class="curse-add"
                            @click="showAuDialog(scope.row, scope.$index)"
                        >
                            {{ scope.row.award_status === 0 ? '审核' : '查看' }}
                        </el-button>
                        <el-button
                            type="text"
                            class="curse-add"
                            @click="handleNext(scope.row)"
                            :disabled="scope.row.award_status === 2 || scope.row.award_status === 1"
                        >
                            通过
                        </el-button>
                        <el-button
                            type="text"
                            class="curse-add"
                            @click="handleError(scope.row)"
                            :style="{marginLeft: '0px'}"
                            :disabled="scope.row.award_status === -1 || scope.row.award_status === 2 || scope.row.award_status === 1"
                        >
                            不通过
                        </el-button>
                        <el-button
                            type="text"
                            class="curse-add"
                            :style="{marginLeft: '0px'}"
                            @click="handleShowMark(scope.row)"
                        >
                            备注
                        </el-button>
                    </template>
                </el-table-column>
            </el-table>
            <!-- /table -->

            <!-- /分页 -->
            <div class="pagination-wrapper clearfix">
                <el-pagination
                    layout="total, prev, pager, next, jumper"
                    background
                    :current-page.sync="page.now_page"
                    :total="page.total_count"
                    :page-size="page.page_size"
                    @current-change="getTableData"
                />
            </div>
        </div>

        <!-- 视频播放组件 -->
        <!-- <video-simple
            ref="videoSimple"
            :url="video_cover"
            :top="54"
            :left="left"
        /> -->

        <!-- 审核弹窗 -->
        <show-dialog
            ref="showDialog"
            :dialog="showDialog"
            :width="360"
            :cancel-text="'取消'"
            :confirm-text="'确认'"
            :title="'温馨提示'"
            :content="`通过后即将${award_money}元奖励金额发送给用户，是否通过?`"
            @close="showDialog = false"
            @emit="emitFun"
        />

        <!-- 驳回原因 -->
        <reject-dialog
            ref="rejectDialog"
            :visible.sync="rejectDialog"
            :reason-detail="''"
            :maxlength="100"
            @confirm="handleVerify"
            :title="'驳回原因'"
        />

        <!-- 备注弹窗 -->
        <mark-dialog
            ref="markDialog"
            :visible.sync="markDialog"
            :reason-detail="''"
            :maxlength="100"
            @confirm="handleMark"
            :title="'备注'"
            :placeholder="'请输入备注内容'"
        />

        <el-dialog
            :visible.sync="dialogVisible"
            :close-on-click-modal="false"
            :title=" '班级信息审核' "
            width="620px"
        >
            <div class="zd-examine">
                <div
                    class="zd-examine-list"
                    :style="{marginBottom: '15px'}"
                >
                    <p class="zd-head-title">当页进度:</p>
                    <div class="zd-examine-line" >
                        <p
                            :style="{ width: 200 * (pageIndex + 1) / pageSize + 'px' }"
                            class="zd-examine-line-length"
                        />
                    </div>
                    <p class="zd-examine-page">{{ (pageIndex + 1) + '/' + pageSize }}</p>
                </div>
                <div class="zd-examine-list">
                    <p class="zd-head-title">学院信息:</p>
                    <div class="zd-info">
                        <p class="zd-info-label">{{ dialogData.college_name ? dialogData.college_name : '--' }}</p>
                    </div>
                </div>
                <div class="zd-examine-list">
                    <p class="zd-head-title">专业信息:</p>
                    <div class="zd-info">
                        <p class="zd-info-label">{{ dialogData.major_name ? dialogData.major_name : '--' }}</p>
                    </div>
                </div>
                <div class="zd-examine-list">
                    <p class="zd-head-title">入学年份:</p>
                    <div class="zd-info">
                        <p class="zd-info-label">{{ dialogData.enter_school_year ? dialogData.enter_school_year : '--' }}</p>
                    </div>
                </div>
                <div class="zd-examine-list">
                    <p class="zd-head-title">班级信息:</p>
                    <div class="zd-info">
                        <p class="zd-info-label">{{ dialogData.class_name ? dialogData.class_name : '--' }}</p>
                    </div>
                </div>
                <div class="zd-examine-list">
                    <p class="zd-head-title">班级qq群号:</p>
                    <div class="zd-info">
                        <p class="zd-info-label">{{ dialogData.class_group_number ? dialogData.class_group_number : '--' }}</p>
                    </div>
                </div>
                <!-- <div
                    class="zd-examine-list"
                    style="align-items: center"
                    :style="{
                        'pointerEvents' : dialog_status ? '' : 'none',
                        marginBottom: '30px'
                    }"
                >
                    <p class="zd-head-title">不通过理由:</p>
                    <el-input
                        type="textarea"
                        :autosize="{ minRows: 2, maxRows: 6}"
                        placeholder="请输入内容"
                        v-model="reason"
                    />
                </div> -->
                <div class="zd-foot">
                    <div class="zd-foot-left">
                        <el-button
                            type="primary"
                            size="mini"
                            style="margin-right: 10px"
                            @click="fnExamineAdopt(dialogData)"
                            v-if="dialog_status"
                        >
                            通过
                        </el-button>
                        <el-button
                            size="mini"
                            @click="fnExamineNoAdopt(dialogData)"
                            v-if="dialog_status"
                        >
                            不通过
                        </el-button>
                        <el-tag
                            type="info"
                            style="cursor: not-allowed"
                            v-if="!dialog_status && (dialogData.award_status === 1 || dialogData.award_status === 2) "
                        >
                            审核通过
                        </el-tag>
                        <el-tag
                            type="info"
                            style="cursor: not-allowed"
                            v-if="!dialog_status && (dialogData.award_status === -1) "
                        >
                            审核未通过
                        </el-tag>
                    </div>
                    <div class="zd-foot-right">
                        <i class="el-icon-arrow-left"/>
                        <p
                            class="zd-foot-prev"
                            @click="fnPrevtData()"
                        >
                            上一条反馈
                        </p>
                        <p
                            class="zd-foot-next"
                            @click="fnNexttData()"
                        >
                            下一条反馈
                        </p>
                        <i class="el-icon-arrow-right"/>
                    </div>
                </div>
            </div>
        </el-dialog>
    </div>
</template>

<script>
// import VideoSimple from "@/components/dorm/video-simple";
import { back } from '@/mixin/back';
import showDialog from '@/components/common/dialog.vue';
import rejectDialog from "@/components/dialog/reject-dialog";
import markDialog from "@/components/dialog/reject-dialog";
// import VerifyDialog from "@/components/dialog/verify-dialog";
export default {
    mixins: [back],
    components: {
        // VerifyDialog,
        // VideoSimple,
        showDialog,
        rejectDialog,
        markDialog
    },
    data () {
        return {
            position_no: '',
            showDialog: false,
            rejectDialog: false,
            markDialog: false,
            formData: {
                keyword: '',
                school_name: '',
                college_name: '',
                class_name: '',
                major_name: '',
                audit_people: '',
                status: 99
            },
            date: [],
            award_date: [],
            auditList: [{ value: 99, label: '全部' },{ value: 0, label: '待审核' },{ value: 1, label: '审核通过' },{ value: -1, label: '审核不通过' },{ value: 2, label: '审核通过' }],
            page: {
                now_page: 1,
                total_count: 0,
                page_size: 0
            },
            tableData: [
                // {
                //     remark: '我是备注信息',
                //     enter_school_year: '2020',
                //     award_fail_reason: '信息不完善',
                //     student_no: 'st_12391230912',
                //     class_no: 'clD_4223423',
                //     agent_level: 5,
                //     award_admin_true_name: '德玛西亚',
                //     phone: 17522291210,
                //     award_time: 1625760000,
                //     major_name: '移动互联应用技术',
                //     class_name: '2班',
                //     college_name: '信息学院',
                //     award_status: 1,
                //     submit_time: 1625780000,
                //     school_name: '国防科技大学',
                //     true_name: '德玛',
                //     award_money: 20.00,
                //     class_group_num: 253162537,
                //     create_no: 'cr_2323232'
                // }
            ],
            authResult: {},
            // 视频播放
            video_cover: '',
            left: 0,
            //审核弹窗
            dialogData: {},
            dialog_status: true,
            reason: '',
            pageIndex: 0,
            pageSize: 0,
            dialogVisible: false,
            nextType: '',//通过方式类型
            award_money: ''
        };
    },
    filters: {
        filterStatus (val) {
            if(val === -1) return '审核不通过';
            if(val === 2 || val === 1) return '审核通过';
            if(val === 0) return '待审核';
        }
    },
    computed: {},
    watch: {},
    mounted () {
        this.$set(this.formData, 'status', this.$route.query.award_status ? Number(this.$route.query.award_status) : 99);
        if(this.$route.query.award_status) {
            this.award_date = [
                Number(this.$route.query.start_time),
                Number(this.$route.query.end_time)
            ];
        }

        this.$store.commit('SET_HEADER', [{ title: "APP后台"},{title: '社交'},{title: '班级管理'},{title: '创建同校班级'}]);
        this.authResult = this.$route.meta.authResult;
        this.getTableData();
    },
    methods: {
        /**
         * @description 获取表格数据
         */
        getTableData (page) {
            this.$post('/student/task_stuagent_extra_class_create%5Cget_list', {
                page_id: page || this.page.now_page,
                keyword: this.formData.keyword,
                school_name: this.formData.school_name,
                college_name: this.formData.college_name,
                major_name: this.formData.major_name,
                class_name: this.formData.class_name,
                award_admin_true_name: this.formData.audit_people,
                award_status: this.formData.status,
                submit_start_time: this.date.length === 0 || this.date === null ? '' : parseInt(new Date(this.date[0]).getTime() / 1000),
                submit_end_time: this.date.length === 0 || this.date === null ? '' : parseInt(new Date(this.date[1]).getTime() / 1000),
                award_start_time: this.award_date.length === 0 || this.award_date === null ? '' : parseInt(new Date(this.award_date[0]).getTime() / 1000),
                award_end_time: this.award_date.length === 0 || this.award_date === null ? '' : parseInt(new Date(this.award_date[1]).getTime() / 1000)
            }, resp => {
                if (resp.code == 1) {
                    this.tableData = resp.data.list;
                    this.page.now_page = resp.data.page.now_page;
                    this.page.total_count = resp.data.page.total_count;
                    this.page.page_size = resp.data.page.page_size;

                    //计算当前页数据数量
                    if(resp.data.page.total_count == 1) {
                        this.pageSize = resp.data.page.total_count;
                    } else if (resp.data.page.total_count > 1 && resp.data.page.next_page > 0) {
                        this.pageSize = 20;
                    } else if (resp.data.page.total_count > 1 && resp.data.page.next_page == 0) {
                        this.pageSize = resp.data.page.total_count - (resp.data.page.now_page - 1) * 20;
                    }
                }
            });
        },

        /**
         * @description 预览视频
         * @param row
         */
        // previewVideo(row) {
        //     this.video_cover = row.video_url;
        //     this.left = this.$refs.wrapper.clientWidth - 300;
        //     this.$refs.videoSimple.showVideo();
        // },

        /**
         * @description 打开审核弹窗
         */
        showAuDialog (row, index) {
            this.dialogData = {
                ...row
            };
            this.pageIndex = index;
            this.dialog_status = row.award_status === 0 ? true : false;
            this.dialogVisible = !this.dialogVisible;
        },

        /**
         * @description 上一条
         */
        fnPrevtData () {
            if(this.pageIndex == 0) {
                this.$notify({
                    title: '提示',
                    message: '当前已经是第一条了',
                    type: 'warning',
                    duration: 2000
                });
                return;
            }

            this.pageIndex--;
            this.dialogData = this.tableData[this.pageIndex];
            this.dialog_status = this.dialogData.award_status === 0 ? true : false;
            if(!this.dialog_status) {
                this.reason = this.dialogData.award_fail_reason;
            }
        },

        /**
         * @description 下一条
         */
        fnNexttData () {
            if(this.pageIndex == this.pageSize - 1) {
                this.$notify({
                    title: '提示',
                    message: '当前已经是最后一条了',
                    type: 'warning',
                    duration: 2000
                });
                return;
            }
            this.pageIndex++;
            this.dialogData = this.tableData[this.pageIndex];
            this.dialog_status = this.dialogData.award_status === 0 ? true : false;
            if(!this.dialog_status) {
                this.reason = this.dialogData.award_fail_reason;
            }
        },

        /**
         * @description 审核通过
         */
        fnExamineAdopt (row) {
            this.award_money = row.award_money;
            this.ID = row.create_no;
            this.showDialog = true;
            this.nextType = '2';
        },

        /**
         * @description 不通过
         */
        fnExamineNoAdopt (row, type) {
            // if (this.reason == '') {
            //     this.$notify({
            //         title: '提示',
            //         message: '请填写不通过理由,不可以为空',
            //         type: 'warning',
            //         duration: 2000
            //     });
            //     return;
            // } else {
            //     this.ID = row.create_no;
            //     this.rejectDialog = true;
            //     this.nextType = '2';
            // }
            this.ID = row.create_no;
            this.rejectDialog = true;
            this.nextType = '2';
        },

        /**
         * @description 打开通过弹窗
         */
        handleNext (row) {
            this.award_money = row.award_money;
            this.ID = row.create_no;
            this.showDialog = true;
            this.nextType = '1';
        },

        /**
         * @description 确定审核该商品
         */
        emitFun () {
            this.$post('/student/task_stuagent_extra_class_create%5Caudit',{
                create_no: this.ID,
                verify: 1
            },resp=>{
                if (resp.code == 1) {
                    this.getTableData();
                    this.$notify({
                        title: '提示',
                        message: '操作成功',
                        type: 'success',
                        duration: 2000
                    });

                    setTimeout(() => {
                        if(this.nextType == '2') {
                            this.dialog_status = false;
                            this.dialogData = this.tableData[this.pageIndex];
                            this.$set(this.dialogData, 'verify', 1);
                        }
                    }, 200);
                } else {
                    this.$notify({
                        title: '提示',
                        message: resp.msg,
                        type: 'warning',
                        duration: 2000
                    });
                }
            });
        },

        /**
         * @description 打开不通过弹窗
         */
        handleError (row) {
            this.ID = row.create_no;
            this.rejectDialog = true;
            this.nextType = '1';
        },

        /**
         * @description 确定驳回
         */
        handleVerify (reson) {
            console.log('reson', reson);
            this.$post('/student/task_stuagent_extra_class_create%5Caudit',{
                create_no: this.ID,
                verify: -1,
                verify_fail_reason: reson
            },resp=>{
                if (resp.code == 1) {
                    this.getTableData();
                    this.$notify({
                        title: '提示',
                        message: '操作成功',
                        type: 'success',
                        duration: 2000
                    });

                    setTimeout(() => {
                        if(this.nextType == '2') {
                            this.dialog_status = false;
                            this.dialogData = this.tableData[this.pageIndex];
                            this.$set(this.dialogData, 'verify', -1);
                        }
                    }, 200);
                } else {
                    this.$notify({
                        title: '提示',
                        message: resp.msg,
                        type: 'warning',
                        duration: 2000
                    });
                }
            });
        },

        /**
         * @description 打开备注弹窗
         */
        handleShowMark (row) {
            this.ID = row.create_no;
            this.markDialog = true;
        },

        /**
         * @description 确定备注
         */
        handleMark (reson) {
            this.$post('/student/task_stuagent_extra_class_create%5Cset_remark',{
                create_no: this.ID,
                remark: reson
            },resp=>{
                if (resp.code == 1) {
                    this.getTableData();
                    this.$notify({
                        title: '提示',
                        message: '操作成功',
                        type: 'success',
                        duration: 2000
                    });
                } else {
                    this.$notify({
                        title: '提示',
                        message: resp.msg,
                        type: 'warning',
                        duration: 2000
                    });
                }
            });
        },

        /**
         * @description 页面跳转
         */
        handleNextPage (pageName, row = {}) {
            this.$router.push({
                name: pageName,
                query: {

                }
            });
        },

        /**
         * @description 时间处理
         */
        pickerOptions () {
            return {
                shortcuts : [{
                    text: '最近一周',
                    onClick(picker) {
                        const end = new Date();
                        const start = new Date();

                        start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
                        picker.$emit('pick', [start, end]);
                    }
                }, {
                    text: '最近一个月',
                    onClick(picker) {
                        const end = new Date();
                        const start = new Date();

                        start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
                        picker.$emit('pick', [start, end]);
                    }
                }, {
                    text: '最近三个月',
                    onClick(picker) {
                        const end = new Date();
                        const start = new Date();

                        start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
                        picker.$emit('pick', [start, end]);
                    }
                }]
            };
        },

        /**
         * @description 过滤函数
         */
        emptyFormatter(row, column, val) {
            if (!val) return '--';
            return val;
        },

        /**
         * 上一条或下一条
         * @param type - next下一步 prev上一步
         */
        changeVerifyData(type) {
            if (type === 'next' && this.pageIndex < this.tableData.length - 1) {
                this.pageIndex++;
                this.dialogData = this.tableData[this.pageIndex];
            }
            if (type === 'prev' && this.pageIndex > 0) {
                this.pageIndex--;
                this.dialogData = this.tableData[this.pageIndex];
            }
        },
    }
};
</script>

<style lang="less" scoped>
.createClass {
    background-color: #fff;
    display: flex;
    flex-direction: column;
    position: relative;
    // width: 100%;
    // height: 100%;
    overflow: hidden;
    margin: 12px;
    .__nav {
        width: 100%;
        height: 67px;
        display: flex;
        align-items: center;
        box-sizing: border-box;
        padding-left: 35px;
        border-bottom: 1px rgba(240, 242, 245, 1) solid;
        margin-bottom: 24px;
        .__nav_title {
            color: rgba(51, 51, 51, 1);
            font-size: 20px;
            font-weight: 500;
            position: relative;
            &::before {
                content: '';
                position: absolute;
                left: -8px;
                top: -1px;
                width: 3px;
                height: 20px;
                background: rgba(24, 144, 255, 1);
            }
        }
    }
    .header-nav {
        position: relative;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        justify-content: space-between;
        box-sizing: border-box;
        padding: 0 32px;
        margin-bottom: 12px;
        .header_left {
            display: flex;
            align-items: center;
            flex-wrap: wrap;
        }
        .__info {
            display: flex;
            align-items: center;
            margin-right: 32px;
            margin-bottom: 12px;
            .__info_title {
                color: rgba(51, 51, 51, 1);
                font-size: 14px;
                margin-right: 12px;
                white-space: nowrap;
            }
        }
        .__left_button {
            flex: 1;
            height: 36px;
            background: rgba(32, 160, 255, 0.1);
            border-radius: 4px;
            border: 1px solid #20A0FF;
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
            // margin-right: 32px;
            color: rgba(32, 160, 255, 1);
            font-size: 14px;
            font-weight: 500;
            .el-icon-hand-iconjia {
                color: rgba(32, 160, 255, 1);
                margin-right: 10px;
                font-size: 14px;
                font-weight: 500;
            }
        }
        .__right_button {
            width: 128px;
            height: 36px;
            background: #FFFFFF;
            border-radius: 4px;
            border: 1px solid #20A0FF;
            text-align: center;
            line-height: 36px;
            color: rgba(32, 160, 255, 1);
            font-size: 14px;
            font-weight: 500;
            cursor: pointer;
        }
    }

    .__wrap {
        width: calc(100% - 64px);
        margin-left: 32px;
        margin-bottom: 12px;
        flex: 1;
        overflow: hidden;
        box-sizing: border-box;
        display: flex;
        flex-direction: column;
    }
    /* 表单 */
    .scope-price {
        width: 50px;
        height: 50px;
    }
    /* 字体高亮 */
    .cursor-font {
        color: rgb(64, 158, 255);
        cursor: pointer;
    }
    /* 分页 */
    .pagination-wrapper {
        padding-top: 10px;
        padding-bottom: 10px;
        .el-pagination {
            float: right;
            padding: 0;
            background-color: transparent;
        }
    }
    .__video {
        width: 90px;
        height: 90px;
        overflow: hidden;
        position: relative;
        cursor: pointer;
        .__video_play {
            position: absolute;
            width: 34px;
            height: 34px;
            left: 28px;
            top: 28px;
            z-index: 1;
        }
    }
}
/* 排序 */
.sort-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    .sort-spliter {
        width: 1px;
        height: 12px;
        background: rgba(235, 235, 235, 1);
        margin: 0 10px;
        }
        .btn-sort {
        font-size: 14px;
        line-height: 1;
        color: #ccc;
        &:hover {
            color: #20a0ff;
        }
    }
}
.el-button-left {
    margin-left: 40px;
}
.el-button-right {
    margin-right: 10px;
}
.__flex {
    display: flex;
    align-items: center;
    .__flex_status {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        margin-right: 5px;
    }
}
.__items {
    display: flex;
    flex-direction: column;
}

/* 审核弹窗 */
.zd-examine {
    width: 100%;
    .zd-examine-list {
        min-height: 20px;
        display: flex;
        // padding-bottom: 30px;
        box-sizing: border-box;
        align-items: flex-start;
        .zd-head-title {
            color: #606285;
            font-size: 14px;
            margin-right: 20px;
            white-space: nowrap;
            // width: 65px;
        }
        .zd-info {
            width: 460px;
            display: flex;
            flex-wrap: wrap;
            .zd-info-label {
                width: 230px;
                min-height: 20px;
                font-size: 14px;
                color: #333;
                margin-bottom: 15px;
                white-space: nowrap;
                cursor: pointer;
                &:hover {
                    i {
                        color: rgb(64, 158, 255);

                    }
                }
            }
        }
        .zd-examine-line {
            width: 200px;
            height: 12px;
            border-radius: 6px;
            background: rgba(64, 158, 255, .2);
            .zd-examine-line-length {
                height: 12px;
                border-radius: 6px;
                background: rgba(64, 158, 255, 1);
                transition: all .5s;
            }
        }
        .zd-examine-page {
            font-size: 14px;
            color: #333;
            margin-left: 10px;
        }
    }
    .zd-foot {
        display: flex;
        justify-content: space-between;
        .zd-foot-left, .zd-foot-right {
            display: flex;
            height: 32px;
            align-items: center;
            cursor: pointer;
            user-select:none;
            .zd-foot-prev {
                font-size: 14px;
                color: #333;
                margin-right: 15px;
                // &:hover {
                //     color: #20a0ff;
                // }
            }
            .zd-foot-next {
                font-size: 14px;
                color: #333;
                // &:hover {
                //     color: #20a0ff;
                // }
            }
        }
    }
}
</style>
<style lang="less">
.createClass{
    .el-table__body-wrapper .el-table__body .el-table__row td {
        border-right: none;
    }
    .el-table__header-wrapper .el-table__header .has-gutter tr th {
        border-right: none;
    }
    .el-table .el-table_1_column_6  .cell {
        position: relative;
    }
    .el-range-editor--small .el-range-separator{
        padding: 0 1px !important;
    }
    .el-dialog__header {
        padding-top: 10px;
        box-shadow:0px 1px 0px 0px rgba(233,233,233,1);
        display: flex;
        align-items: center;
        background: #FAFAFA;
        border-radius: 4px 4px 0 0;
        .el-dialog__title {
            font-weight: 500;
            color: #333;
            font-size: 14px;
        }
        .el-icon-close:before {
            color: rgb(194,194,194);
            font-size: 17px;
            font-weight: bold;
        }
        .el-dialog__headerbtn {
            top: 14px;
        }
    }
}
</style>
